package sctu.edu.java.year2016.team03.maoyuhao.day20160522.chapter5_2;

/**
 * 创建一维数序arr 并输出其最小值
 * Created by cc on 2016/5/22.
 */
public class Work {
    public static void main(String[] args) {
        int[] arr = {2, 5, 6, 8, 9, 24, 5, 1, 0, 3};
        for (int i = 0; i < 10; i++)
            System.out.print(arr[i] + "  ");
        System.out.println(" ");
        int min=arr[0];
        for(int j=0;j<10;j++ )
            if(min>arr[j])
                min=arr[j];
        System.out.println("最小值为 "+min);
    }
}

